package eerbaar.v2.menu;

import java.awt.Graphics2D;

import eerbaar.v2.app.tasks.IGameTask;
import eerbaar.v2.graphics.Text;

public class DisplayMenuTask implements IGameTask {

    // private MainWindow window;

    @Override
    public void doTask(Graphics2D g) {

        // if (this.window == null) {
        // IApp app = App.instance();
        // this.window = app.getMainWindow();
        // }

        // Canvas c = this.window.getCanvas();
        // Graphics2D g = (Graphics2D) c.getBufferStrategy().getDrawGraphics();

        g.setFont(Text.FONT);

        Menu menu = new Menu();
        menu.draw(g);
    }

    @Override
    public Priority getPriority() {
        return Priority.AFTER_AFTER_LAST;
    }

    @Override
    public int getRate() {
        return 1;
    }

    @Override
    public boolean runWhenSuspended() {
        return false;
    }

}
